// 获取角色列表
export function getMenuList() {
  return {
    // isOpen: false,
    url: 'sys/sysRoleMgr/pageList',
    type: 'get',
    data: {
      msg: 'success',
      code: '0',
      data: {
        currentPageNum: 1,
        hasNext: true,
        hasPrevious: false,
        lastPageNum: 4,
        pageSize: 10,
        records: [
          {
            cmntStr: 'string',
            createTm: '2019-03-14T07:51:45.742Z',
            creatorId: 1,
            roleCode: 'admin',
            roleDesc: '这是管理员',
            roleId: 1,
            roleNm: '管理员',
            status: 0,
            sysRole: true,
            updateTm: '2019-03-14T07:51:45.742Z',
            updaterId: 1
          },
          {
            cmntStr: 'string',
            createTm: '2019-03-14T07:51:45.742Z',
            creatorId: 1,
            roleCode: 'user1',
            roleDesc: '这是用户1',
            roleId: 2,
            roleNm: '用户1',
            status: 0,
            sysRole: false,
            updateTm: '2019-03-14T07:51:45.742Z',
            updaterId: 1
          },
          {
            cmntStr: 'string',
            createTm: '2019-03-14T07:51:45.742Z',
            creatorId: 1,
            roleCode: 'user2',
            roleDesc: '这是用户2',
            roleId: 3,
            roleNm: '用户2',
            status: 0,
            sysRole: false,
            updateTm: '2019-03-14T07:51:45.742Z',
            updaterId: 1
          },
          {
            cmntStr: 'string',
            createTm: '2019-03-14T07:51:45.742Z',
            creatorId: 1,
            roleCode: 'user3',
            roleDesc: '这是用户3',
            roleId: 4,
            roleNm: '用户3',
            status: 0,
            sysRole: false,
            updateTm: '2019-03-14T07:51:45.742Z',
            updaterId: 1
          },
          {
            cmntStr: 'string',
            createTm: '2019-03-14T07:51:45.742Z',
            creatorId: 1,
            roleCode: 'user4',
            roleDesc: '这是用户4',
            roleId: 5,
            roleNm: '用户4',
            status: 0,
            sysRole: false,
            updateTm: '2019-03-14T07:51:45.742Z',
            updaterId: 1
          },
          {
            cmntStr: 'string',
            createTm: '2019-03-14T07:51:45.742Z',
            creatorId: 1,
            roleCode: 'user5',
            roleDesc: '这是用户5',
            roleId: 6,
            roleNm: '用户5',
            status: 0,
            sysRole: false,
            updateTm: '2019-03-14T07:51:45.742Z',
            updaterId: 1
          },
          {
            cmntStr: 'string',
            createTm: '2019-03-14T07:51:45.742Z',
            creatorId: 1,
            roleCode: 'user6',
            roleDesc: '这是用户6',
            roleId: 7,
            roleNm: '用户6',
            status: 0,
            sysRole: false,
            updateTm: '2019-03-14T07:51:45.742Z',
            updaterId: 1
          },
          {
            cmntStr: 'string',
            createTm: '2019-03-14T07:51:45.742Z',
            creatorId: 1,
            roleCode: 'user7',
            roleDesc: '这是用户7',
            roleId: 8,
            roleNm: '用户7',
            status: 0,
            sysRole: false,
            updateTm: '2019-03-14T07:51:45.742Z',
            updaterId: 1
          },
          {
            cmntStr: 'string',
            createTm: '2019-03-14T07:51:45.742Z',
            creatorId: 1,
            roleCode: 'user8',
            roleDesc: '这是用户8',
            roleId: 9,
            roleNm: '用户8',
            status: 0,
            sysRole: false,
            updateTm: '2019-03-14T07:51:45.742Z',
            updaterId: 1
          },
          {
            cmntStr: 'string',
            createTm: '2019-03-14T07:51:45.742Z',
            creatorId: 1,
            roleCode: 'user9',
            roleDesc: '这是用户9',
            roleId: 10,
            roleNm: '用户9',
            status: 0,
            sysRole: false,
            updateTm: '2019-03-14T07:51:45.742Z',
            updaterId: 1
          }
        ],
        totalSize: 35
      }
    }
  }
}

export function getRoleDetail() {
  return {
    url: 'sys/sysRoleMgr',
    type: 'get',
    data: {
      msg: 'success',
      code: '0',
      data: {
        cmntStr: 'string',
        createTm: '2019-03-14T07:51:45.742Z',
        creatorId: 1,
        roleCode: 'user9',
        roleDesc: '这是用户9',
        roleId: 10,
        roleNm: '用户9',
        status: 0,
        sysRole: false,
        menuIds: [5, 7, 3, 2],
        updateTm: '2019-03-14T07:51:45.742Z',
        updaterId: 1
      }
    }
  }
}

export function updateRole() {
  return {
    url: 'sys/sysRoleMgr',
    type: 'put',
    data: {
      msg: 'success',
      code: '0',
      data: '操作成功'
    }
  }
}
